package ${servicePackage};

import java.util.List;

import ${daoPackage}.${modular}.db.domain.${tableNameHump?cap_first};
import ${queryPackage}.${queryModel?cap_first};

public interface I${tableNameHump?cap_first}SV {

	/**
	 * 搜索${description}
	 <#list searchs as search>
	 * @param   ${search.humpName} ${search.javaType} ${search.description} 
	 </#list>
	 * @return List<${tableNameHump?cap_first}>
	 * @throws Exception
	 */
	public List<${tableNameHump?cap_first}> queryList(${queryModel?cap_first}  ${queryModel?cap_first} ,int offset, int limit, String sort, String order);

	/**
	 * 搜索${description}
	 <#list searchs as search>
	 * @param   ${search.name} ${search.javaType} ${search.description} 
	 </#list>
	 * @return int
	 * @throws Exception
	 */
	public long queryTotal(${queryModel?cap_first}  ${queryModel?uncap_first});
	
	
	/**
	 * 根据Id获取${description}
	 * @param id
	 * @return
	 */
	public ${tableNameHump?cap_first} findById(long id);
	
	/**
	 * 新增${description}
	 * @param ${tableNameHump}
	 * @return
	 */
	public ${tableNameHump?cap_first} add(${tableNameHump?cap_first} ${tableNameHump?uncap_first});
	
	/**
	 * 根据更新${description}
	 * @param ${tableNameHump}
	 */
	public int updateById(${tableNameHump?cap_first} ${tableNameHump?uncap_first});
	
	/**
	 * 删除${description}
	 * @param id
	 * @throws Exception
	 */
	public void delete(long id);


}
